package com.taomus.mytools.simplec.common;

import java.util.Stack;

import com.taomus.mytools.simplec.generate.Token;
import com.taomus.mytools.simplec.generate.WordEnum;

public final class Label {
	private final static Stack<Token> l = new Stack<>();
	private static int num = 0;
	
	public static Token create(){
		String labelName = "label_"+num++;
		Token temp = new Token(WordEnum.LABEL,labelName,labelName);
		l.push(temp);
		return temp;
	}
	public static Token peek(){
		return l.peek();
	}
	public static Token pop(){
		return l.pop();
	}
	public static boolean isEmpty(){
		return l.isEmpty();
	}
	
}
